<?php
/**
 * 渠道配置通道
 * @Author: lf
 * @Date:   2018-07-03T17:11:00+0800
 */
namespace app\admin\controller;

use app\admin\model\BusChannelSendConfig;


class SmsPlatPrice extends Father {
	/**
	 * 首页
	 * @Author   lf
	 * @DateTime 2018-07-03T17:11:00+0800
	 * @return   [type]                   [description]
	 */
	public function index() {
		if (input('get.api')) {
			$request = input('get.');
			$data = BusChannelSendConfig::getAll($request);
			return json(['code' => 0, 'msg' => '', 'count' => $data['total'], 'data' => $data['data']]);
		} else {
			$this->assign('countryCodeInfo', db('bus_country_code')->select());
			return $this->fetch();
		}
	}
}
